<?php
	session_start();
?>
<table id="menumuc_a_table" align="center" width="100%">
<tr>
	<td width="125px" align="right">Mã mục menu: </td>
    <td><input type="text" id="id" value="" size="10" disabled="disabled" /></td>
</tr>
<tr>
	<td align="right">Tên mục menu: </td>
    <td><input type="text" id="ten" value="" size="30" /></td>
</tr>
<tr>
	<td align="right">Nhóm: </td>
    <td><div id="idmenunhom"></div>
    <input id="idmenunhom1" type="hidden" value=""/></td>
</tr>
<tr>
	<td align="right">Mô tả:  </td>
    <td><textarea id="mota" cols="30" rows="3"></textarea></td>
</tr>
<tr>
	<td align="right">Sử dụng:  </td>
    <td>
        <select id="chophep">
        	<option value="1">Cho phép</option>
            <option value="0">Cấm</option>
        </select>
    </td>
</tr>
<tr>
	<td align="right">Ngày tạo: </td>
    <td><input id="ngaytao" type="text" value="<?php echo date("Y-n-j G:i:s");?>" disabled="disabled" /></td>
</tr>
<tr>
	<td align="right">Người tạo: </td>
    <td><input id="un" type="text" value="<?php echo $_SESSION["un"];?>" disabled="disabled" /></td>
</tr>
</table>
<script type="text/javascript" language="javascript">
	$("#menumuc_a_table #idmenunhom").flexbox("modules/menunhom/json.php",{
		resultTemplate: "<tr><td>{id}</td><td>{name}</td></tr>",
		watermark: "Chọn nhóm",
		paging: {pageSize:5},
		allowInput: true,
		width: 250,
		onSelect: function() {
			$("#menumuc_a_table #idmenunhom1").attr("value",this.getAttribute("hiddenValue"));
		}
	});
</script>
